import { useState } from 'react'
import reactLogo from './assets/react.svg'
import { connect} from 'react-redux'
import './App.css'
import Index from '@/pages/Index'
import Login from '@/pages/Login'

function App(props) {
 const { login } = props
  return (
    <div className="App">
    {
        login? <Index/>:<Login/>
    }
    </div>
  )
}
const mapStateProps = (state) => ({
  login: state.login
})
export default connect(mapStateProps)(App)
